<template>
	<view>
		<u-tabs :list="list" :is-scroll="true" :current="current" @change="change"></u-tabs>
		<participate v-if="current == 0"></participate>
		<initiate v-if="current == 1"></initiate>
		<proxy v-if="current == 2"></proxy>
		<createWork v-if="current == 3"></createWork>
		<!-- <tabbar></tabbar> -->
	</view>
</template>

<script>
	import tabbar from '../../components/tabbar/index.vue';
	import participate from './participate'
	import initiate from './initiate'
	import proxy from './proxy'
	import createWork from './createWork'
	export default {
		components: {
			tabbar,
			participate,
			initiate,
			createWork,
			proxy
		},
		data() {
			return {
				list: [{
					name: '参与的工单'
				}, {
					name: '发起的工单'
				}, {
					name: '待办工单'
				}, {
					name: '新建工单'
				}],
				current: 0
			}
		},
		methods: {
			change (index) {
				this.current = index;
			}
		}
	}
</script>

<style>
</style>